package arbitration.gui;


import javax.swing.*;
import java.awt.*;
import javax.swing.border.EtchedBorder;
import javax.swing.border.LineBorder;
/**
 * Status panel
 * @author Startsev S.S.
 * @version 1.0
 * @see JPanel
 */
public class StatusPanel extends JPanel{
    /**
     * status label
     */
    private JLabel l1;
    private JLabel l2;
    /**
     * default constructor
     */
    StatusPanel(){
        this.setLayout(new GridBagLayout());
        JPanel p=new JPanel();
        p.setLayout(new BorderLayout());
        p.setBorder(BorderFactory.createEtchedBorder(EtchedBorder.LOWERED));
        l1=new JLabel(" first status");
        l1.setFont(new Font("Tahoma", Font.TRUETYPE_FONT, 11));        
        p.add(l1,BorderLayout.WEST);
        this.add(p,new GridBagConstraints(0, 0, 1, 1, 1, 0, GridBagConstraints.WEST,
            GridBagConstraints.HORIZONTAL, new Insets(4, 0, 0, 0), 0, 0));

        JPanel p1=new JPanel();
        p1.setLayout(new BorderLayout());
        p1.setBorder(BorderFactory.createEtchedBorder(EtchedBorder.LOWERED));
        l2=new JLabel(" second panel");
        l2.setFont(new Font("Tahoma", Font.TRUETYPE_FONT, 11));
        p1.add(l2,BorderLayout.WEST);
        this.add(p1,new GridBagConstraints(1, 0, 1, 1, 10, 0, GridBagConstraints.WEST,
            GridBagConstraints.HORIZONTAL, new Insets(4, 0, 0, 0), 0, 0));
    }

    public void setL1(String l1) {
        this.l1.setText(" "+l1);
    }

    public void setL2(String l2) {
        this.l2.setText(" "+l2);
    }
    
}
